home *** CD-ROM | disk | FTP | other *** search
/ InfoMagic Internet Tools 1993 July / Internet Tools.iso / RockRidge / info-service / gopher / Unix / gopher1.12 / object / compatible.h < prev    next >
Encoding:
C/C++ Source or Header  |  1993-01-14  |  3.5 KB  |  142 lines

  1. /********************************************************************
  2.  * $Author: lindner $
  3.  * $Revision: 1.7 $
  4.  * $Date: 1993/01/14 21:58:02 $
  5.  * $Source: /home/mudhoney/GopherSrc/gopher1.11b/object/RCS/compatible.h,v $
  6.  * $State: Rel $
  7.  *
  8.  * Paul Lindner, University of Minnesota CIS.
  9.  *
  10.  * Copyright 1991, 1992 by the Regents of the University of Minnesota
  11.  * see the file "Copyright" in the distribution for conditions of use.
  12.  *********************************************************************
  13.  * MODULE: compatible.h
  14.  * Header file to make things compatible and define stuff in compatible.c
  15.  *********************************************************************
  16.  * Revision History:
  17.  * $Log: compatible.h,v $
  18.  * Revision 1.7  1993/01/14  21:58:02  lindner
  19.  * Added #define that makes compatible compile fine under UCX
  20.  *
  21.  * Revision 1.6  1993/01/11  19:56:20  lindner
  22.  * Fixed prototype for strcasecmp
  23.  *
  24.  * Revision 1.5  1993/01/09  02:25:57  lindner
  25.  * Added definition for SIG_ERR for systems that don't have it.
  26.  *
  27.  * Revision 1.4  1993/01/08  23:17:20  lindner
  28.  * Added more mods for VMS.
  29.  *
  30.  * Revision 1.3  1993/01/06  23:09:44  lindner
  31.  * Added definition for AIX370 for strdup()
  32.  *
  33.  * Revision 1.2  1992/12/31  04:42:02  lindner
  34.  * Changes for VMS, new switch NO_STRCASECMP
  35.  *
  36.  * Revision 1.1  1992/12/10  23:27:52  lindner
  37.  * gopher 1.1 release
  38.  *
  39.  *
  40.  *********************************************************************/
  41. /*
  42.  * Protoize a little 
  43.  */
  44.  
  45. #ifndef compatible_h_
  46. #define compatible_h_
  47.  
  48. /******************** for SIG_ERR **/
  49. #ifndef SIG_ERR
  50. #  ifdef __STDC__
  51. #    define SIG_ERR         ((void (*) (int))-1)
  52. #  else
  53. #    define SIG_ERR         ((void (*) ())-1)
  54. #  endif        /* __STDC__ */
  55. #endif        /* SIG_ERR */
  56.  
  57.  
  58.  
  59. /******************** for strstr() **/
  60.  
  61. #if defined(NOSTRSTR) || (defined(mips) && !defined(ultrix)) || defined(sequent) || defined(n16) || defined(sony_news)
  62. #undef  NOSTRSTR
  63. #define NOSTRSTR
  64. char *strstr();
  65. #endif
  66.  
  67. /******************** for tempnam() **/
  68.  
  69. #if defined(__convex__) || defined(NeXT) || defined(sequent) || defined(VMS) || defined(NO_TEMPNAM)
  70. #undef  NO_TEMPNAM
  71. #define NO_TEMPNAM
  72. char *tempnam();
  73. #endif
  74.  
  75. /******************************** for strdup() **/
  76.  
  77. #if defined(mips) || defined(ultrix) || defined(NeXT) || defined(sony_news) || defined(sequent) || defined (VMS) || defined(_AUX_SOURCE) || defined(_AIX370) || defined(NO_STRDUP) 
  78. #undef  NO_STRDUP
  79. #define NO_STRDUP
  80. char *strdup();
  81. #endif
  82.  
  83. /********************** For bzero()/bcopy() etc */
  84.  
  85. #if defined(USG) || defined(NO_BZERO) || defined(_SEQUENT_) || defined(VMS)
  86.  
  87. #define bzero(a,b)   memset(a,'\0',b)
  88. #define bcopy(a,b,c) memcpy(b,a,c)
  89.      
  90. #endif
  91.  
  92. /********************* For getwd() */
  93.  
  94. #if defined(M_XENIX) || defined(hpux) || defined(USG) || defined(NO_GETWD)
  95. # define getwd(a) getcwd(a,sizeof(a))
  96. #endif
  97.  
  98. /********************* For tzset() */
  99.  
  100. #if defined(NO_TZSET) || defined(sequent)
  101. #undef  NO_TZSET
  102. #define NO_TZSET
  103. void tzset();
  104. #endif
  105.  
  106. /******************** For strcasecmp() */
  107.  
  108. #if defined(NO_STRCASECMP) || defined(VMS) 
  109. #  undef NO_STRCASECMP
  110. #  define NO_STRCASECMP
  111. int strcasecmp();
  112. #endif
  113.  
  114. /********************* For VMS */
  115.  
  116. #if defined(VMS)
  117. #  define popen(a,b) fopen(a,b)
  118. #  define pclose(a)  fclose(a)
  119. #  define unlink delete
  120.  
  121. #  define fopen fopen_VMSopt
  122.    FILE *fopen_VMSopt();
  123. #  define open open_VMSopt
  124.    int open_VMSopt();
  125.  
  126. #  if defined(UCX)
  127. #    define closenet close
  128. #  endif
  129.  
  130. #else
  131.    /* non-VMS systems don't need a special netclose either */
  132. #  define closenet close
  133.  
  134. #endif  /** VMS **/
  135.  
  136. #endif  /* compatible_h_ */
  137.  
  138.  
  139.  
  140.  
  141.  
  142.